package com.example.administrator.runbook.fragments.community.fragment;


import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;

import com.example.administrator.runbook.R;
import com.example.administrator.runbook.fragments.CommonFragment;

/**
 * A simple {@link Fragment} subclass.
 */
public class TrendsFragment extends CommonFragment implements View.OnClickListener {


    private Button button;

    public TrendsFragment() {
        // Required empty public constructor
    }


    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {
        // Inflate the layout for this fragment
        View view = inflater.inflate(R.layout.fragment_trends, container, false);
        button = (Button) view.findViewById(R.id.bt_login_trends_fragment);
        initListener();
        return view;
    }

    private void initListener() {

        button.setOnClickListener(this);
    }


    @Override
    public String getTitle() {
        return "动态";
    }

    @Override
    public void onClick(View v) {

        LoginDialogFragment fragment = new LoginDialogFragment();
        fragment.show(getFragmentManager(), "login");
    }
}
